import Vue from 'vue'

let oldArrayPrototype = Vue.prototype;
let proto = Object.create(oldArrayPrototype);
proto.$toast=function(arg){
    if(typeof arg==='string'){
        arg=arg.trim();
    }else if(Object.prototype.toString.call(arg)=='[object Object]'){
        if(typeof arg.message==='string'){
            arg.message=arg.message.trim();
        }
    }
    oldArrayPrototype.$toast.call(this, arg)
}
Vue.prototype=proto;